﻿using System;
using System.Collections.Generic;
using System.Text;

namespace SharpSoft.Data
{
    /// <summary>
    /// 外键描述
    /// </summary>
    public class ForeignKeyDescriptor
    {
        public ForeignKeyDescriptor()
        {

        }
        public ForeignKeyDescriptor(ForeignKeyAttribute foreignKey)
        {
            this.ModelType = foreignKey.ForeignModelType;
            this.PropertyName = foreignKey.ForeignProperty;
        }
        public ForeignKeyDescriptor(Type modelType, string propertyName)
        {
            this.ModelType = modelType;
            this.PropertyName = propertyName;
        }
        public Type ModelType { get; set; }

        public string PropertyName { get; set; }
    }
}
